package OceanWorld2;

/**
 * Created by pc on 3/31/16.
 */
public class Ocean {
    public static void main(String[] args) {
        doSwim(new Anemonefish("Nimo"));
        doSwim(new Shark("Lanni"));
        doSwim(new SwimPlayer("Justin"));
        doSwim(new Submarine("Yellow I"));
        doSwim(new FlyingFish("Shenping"));
    }

    static void doSwim(Swimmer swimmer) {
        swimmer.swim();
    }
}
